It is known to provide media proxies to enable traffic to pass through NAT (network address translation) entities used in gateways to private networks such as LANs and VPNs (Virtual Private Networks). Traffic may be communication sessions in the form of data traffic or calls such as VoIP or video conferencing traffic. The NAT is needed to allow the devices in the private domain of an enterprise using the enterprise IP addresses (frequently using the reserved IP private address range 10.x.x.x) to establish communication with the devices in a carrier data network using its own IP addressing scheme, using either public or private IP addressing. A media gateway typically communicates with a call server to establish calls to a far end gateway. The call server selects one gateway to complete the call. Because of the NAT, the call server cannot simply provide the enterprise media gateway and the far end gateway with each others respective IP addresses and let the gateways send VoIP packets to each other as would normally be the case. The IP addresses for each gateway are corrupted by the NAT operation. To get around this problem, the call server can put in the call path specialized media proxies whose operation allows both gateways to communicate with each other. The call server instructs the enterprise media gateway and the far end gateway to send their packets to the media proxy. Essentially the media proxy patches together the two legs of the VoIP flow coming from the enterprise media gateway and from the far end gateway, as instructed by the call server by learning the translated source IP addresses and ports from VoIP packets sent to it. The learnt addresses and ports are then used as the destination addresses and ports for the return flow.
A media proxy is defined as a device which enables successful NAT traversal by providing a common target point in the external network for the originating and terminating endpoints of a communication session where one or both the originating and terminating endpoints are behind NAT. The media proxy is configured to relay the traffic stream from one end point to the other by manipulating the source and destination IP addresses of the traffic stream. This is also called a “twice NAT” function.